<template>
	<view class="box">
		<u--form labelPosition="left" :model="detail" labelWidth="auto">
			<u-form-item label="项目名称" borderBottom>
				<u--input v-model="detail.xmmc" disabled border="none"></u--input>
			</u-form-item>
			<u-form-item label="持有方名称" borderBottom>
				<u--input v-model="detail.cgcyfmc" disabled border="none"></u--input>
			</u-form-item>
			<u-form-item label="联系人" borderBottom>
				<u--input v-model="detail.lxr" disabled border="none"></u--input>
			</u-form-item>
			<u-form-item label="联系电话" borderBottom>
				<u--input v-model="detail.lxrdh" disabled border="none"></u--input>
			</u-form-item>
			<u-form-item label="技术水平" borderBottom>
				<u--input v-model="detail.jsspName" disabled border="none"></u--input>
			</u-form-item>
			<u-form-item label="是否中试" borderBottom>
				<u--input v-model="detail.sfzsName" disabled border="none"></u--input>
			</u-form-item>
			<u-form-item label="产业领域" borderBottom>
				<u--input v-model="detail.cylyName" disabled border="none"></u--input>
			</u-form-item>
			<u-form-item label="转化方式" borderBottom>
				<u--input v-model="detail.hzfsName" disabled border="none"></u--input>
			</u-form-item>
			<u-form-item label="需投入资金/（元）" borderBottom>
				<u--input v-model="detail.yjtzgmName" disabled border="none"></u--input>
			</u-form-item>
			<u-form-item label="预期经济效益" borderBottom>
				<u--textarea v-model="detail.yqjjxy" autoHeight disabled border="none"></u--textarea>
			</u-form-item>
			<u-form-item label="成果内容" borderBottom>
				<u--textarea v-model="detail.cgnrjzms" autoHeight disabled border="none"></u--textarea>
			</u-form-item>
		</u--form>
	</view>
</template>

<script>
import * as kjcgzh from '@/api/source/kjcg/kjcgzh.js';
import * as data from "@/api/system/dict/data" 
export default {
	data() {
		return {
			detail: {},
			jsspList:[]
		};
	},
	onLoad(option) {
		this.getcgzhDetail(option.id);
	},
	methods: {
		getcgzhDetail(id) {
			kjcgzh.getcgzhDetail(id).then((res) => {
				this.detail = res.data;
				this.getDict()
			});
		},
		getDict(){
			data.getDicts('xmyq').then((res)=>{
				this.$set(this.detail,'jsspName',res.data.find(item=>item.dictValue===this.detail.jssp).dictLabel)
			})
			data.getDicts('sys_yes_no').then((res)=>{
				this.$set(this.detail,'sfzsName',res.data.find(item=>item.dictValue===this.detail.sfzs).dictLabel)
			})
			data.getDicts('cms_industry_type').then((res)=>{
				this.$set(this.detail,'cylyName',res.data.find(item=>item.dictValue===this.detail.cyly).dictLabel)
			})
			data.getDicts('tzfs').then((res)=>{
				this.$set(this.detail,'hzfsName',res.data.find(item=>item.dictValue===this.detail.hzfs).dictLabel)
			})
			data.getDicts('ntrzj').then((res)=>{
				this.$set(this.detail,'yjtzgmName',res.data.find(item=>item.dictValue===this.detail.yjtzgm).dictLabel)
			})
		},
	}
};
</script>

<style lang="scss" scoped>
.box {
	padding: 20rpx;
	.title {
		text-align: center;
		font-weight: 700;
		font-size: 36rpx;
	}
}
</style>
